package org.jeecg.modules.experiment.service.impl;

import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import org.jeecg.modules.course.entity.AstuCourse;
import org.jeecg.modules.experiment.entity.AstuExperiment;
import org.jeecg.modules.experiment.mapper.AstuExperimentMapper;
import org.jeecg.modules.experiment.service.IAstuExperimentService;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.List;

/**
 * @Description: 实验表
 * @Author: jeecg-boot
 * @Date:   2020-11-05
 * @Version: V1.0
 */
@Service
public class AstuExperimentServiceImpl extends ServiceImpl<AstuExperimentMapper, AstuExperiment> implements IAstuExperimentService {
    @Resource
    private AstuExperimentMapper astuExperimentMapper;

    @Override
    public String selectCourseIdByCourseName(String courseName) {
        return astuExperimentMapper.selectCourseIdByCourseName(courseName);
    }

    @Override
    public List<AstuCourse> selectCourseNameAndTeacherNumberAndTeacherNumber() {
        return astuExperimentMapper.selectCourseNameAndTeacherNumberAndTeacherNumber();
    }

    @Override
    public List<AstuExperiment> selectByMainId(String mainId) {
        return astuExperimentMapper.selectByMainId(mainId);
    }

    @Override
    public String selectExperimentNumberById(String id) {
        return astuExperimentMapper.selectExperimentNumberById(id);
    }

    @Override
    public List<AstuExperiment> selectAllExperimentNum() {
        return astuExperimentMapper.selectAllExperimentNum();
    }

    @Override
    public AstuExperiment selectInfoByCourseNumAndExperimentNum(String courseId, String experimentSerialNumber) {
        return astuExperimentMapper.selectInfoByCourseNumAndExperimentNum(courseId, experimentSerialNumber);
    }
}
